//
//  XMLUtil.h
//  backpack
//
//  Created by wujian on 16/9/3.
//  Copyright © 2016年 wujian. All rights reserved.
//

#import <Foundation/Foundation.h>

@protocol XMLUtilDelegate <NSObject>

-(void)parseComplete:(NSMutableArray *)list;

@end

@interface XMLUtil : NSObject<NSXMLParserDelegate>

//添加属性
@property (nonatomic, strong) NSXMLParser *par;

//存放每个person
@property (nonatomic, strong) NSMutableArray *list;

//标记当前标签，以索引找到XML文件内容
@property (nonatomic, copy) NSString *currentElement;


@property (nonatomic,weak) id<XMLUtilDelegate> delegate;
//声明parse方法，通过它实现解析
-(void)parse:(NSString *)path;

@end
